package com.fzkj.utc;

import java.text.SimpleDateFormat;
import java.util.Date;
import java.util.TimeZone;

public class Test {

    public static void main(String[] args) {
        String time = "2021-01-31T14:21:24.929Z";
        SimpleDateFormat sdf = new SimpleDateFormat();
        sdf.setTimeZone(TimeZone.getTimeZone("UTC"));

        try{
            Date date = sdf.parse("2021-01-31T14:21:24.929Z");
            System.out.println("date: " + date);
        }catch (Exception e){
            e.printStackTrace();
        }
    }
}
